//package com.info.zhiduoduo.admin.controller;
//
//import com.info.zhiduoduo.admin.model.formbean.crowdsourcedeposit.ListDepositFormBean;
//import com.info.zhiduoduo.admin.model.formbean.crowdsourcedeposit.SettleDepositFormBean;
//import com.info.zhiduoduo.admin.service.CrowdsourceDepositService;
//import com.info.zhiduoduo.common.annotation.LogEntity;
//import com.info.zhiduoduo.common.annotation.ZddLog;
//import com.info.zhiduoduo.common.constants.SmartResult;
//import com.info.zhiduoduo.common.constants.StatusMsg;
//import com.info.zhiduoduo.common.constants.system.ZddLogType;
//import com.info.zhiduoduo.common.formbean.BaseSimpleFormBean;
//import com.info.zhiduoduo.common.utils.ContextUtil;
//import com.info.zhiduoduo.common.utils.DateUtil;
//import com.info.zhiduoduo.repository.dto.crowdsource.CrowdsourceMonthlyDepositDto;
//
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.format.annotation.DateTimeFormat;
//import org.springframework.web.bind.annotation.PostMapping;
//import org.springframework.web.bind.annotation.RequestBody;
//import org.springframework.web.bind.annotation.RequestMapping;
//import org.springframework.web.bind.annotation.RequestParam;
//import org.springframework.web.bind.annotation.RestController;
//
//import java.util.Date;
//
//import javax.validation.Valid;
//
//import io.swagger.annotations.ApiOperation;
//import io.swagger.annotations.ApiParam;
//
//@RestController
//@RequestMapping("/crowdsource/deposit")
//public class CrowdsourceDepositController {
//
//	@Autowired
//	CrowdsourceDepositService crowdsourceDepositService;
//
//
//	@ApiOperation("获取保证金列表")
//	@PostMapping("/list")
//	public SmartResult<CrowdsourceMonthlyDepositDto> list(@Valid @RequestBody BaseSimpleFormBean<ListDepositFormBean> formBean) {
//		return crowdsourceDepositService.list(formBean);
//	}
//
//	@ZddLog(type = ZddLogType.UPDATE,name = "确认返还")
//	@ApiOperation("确认返还")
//	@PostMapping("/settleDeposit")
//	public SmartResult settleDeposit(@Valid @RequestBody BaseSimpleFormBean<SettleDepositFormBean> formBean) {
//		return crowdsourceDepositService.settleDeposit(formBean);
//	}
//
//	@ApiOperation("计算并记录保证金(只用作测试环境)")
//	@PostMapping("/calcAndRecordDeposit")
//	public SmartResult calcAndRecordDeposit(@ApiParam("月份 yyyy-MM") @RequestParam("month") String month) {
//		Date date = DateUtil.getDateMonthBeginDate(DateUtil.parseDate(month,"yyyy-MM"));
//		crowdsourceDepositService.recordCompanyCrowdsourceDeposit(date);
//		return SmartResult.success();
//	}
//
//}
